package nowcoder.written_examination;

import java.util.Scanner;

/**
 * @author fance
 * @date 18-7-3 上午3:41
 */
public class MainI {
    public static void main(String[] args) {
            Scanner scanner = new Scanner(System.in);
            while (scanner.hasNext()) {
                int n = scanner.nextInt();
            int[] cnt = new int[10];
            for (int i = 1; i <= n; i++) {
                cntCore(cnt,String.valueOf(i));
            }
            for (int i = 0; i < 9; i++) {
                System.out.print(cnt[i] + " ");
            }
            System.out.println(cnt[9]);
        }
    }
    public static void cntCore(int[] cnt,String s) {
        for (int i = 0; i < s.length(); i++) {
            cnt[s.charAt(i) - '0']++;
        }
    }
}
   /* public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        while (scanner.hasNext()) {
            int n = scanner.nextInt();
            int l = scanner.nextInt();
            int i = 0;
            int j = 0;
            List<List<Integer>> res = new ArrayList<>();
            while (j <= n) {
                int curSum = seqSum(i,j);
                if (curSum == n) {
                    res.add(seq(i,j));
                    j++;
                } else if (curSum > n) {
                    i++;
                } else {
                    j++;
                }
            }
            int index = -1;
            int min = n;
            for (int k = 0; k < res.size(); k++) {
                if (res.get(k).size() < min && res.get(k).size() >= l) {
                    min = res.get(k).size();
                    index = k;
                }
            }
            if (index == -1 || min > 100) {
                System.out.println("No");
            } else {
                int k = 0;
                for (; k < res.get(index).size() - 1; k++) {
                    System.out.print(res.get(index).get(k) + " ");
                }
                System.out.println(res.get(index).get(k));
            }

        }
    }
    private static List<Integer> seq(int lo,int hi) {
        List<Integer> res = new ArrayList<>();
        for (int i = lo; i <= hi; i++) {
            res.add(i);
        }
        return res;
    }
    private static int seqSum(int lo,int hi) {
        int sum = 0;
        for (int i = lo; i <= hi; i++) {
            sum += i;
        }
        return sum;
    }
}*/
 /*   public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        while (scanner.hasNext()) {
            int n  = scanner.nextInt();
            int[] a = new int[n];
            for (int i = 0; i < n; i++) {
                a[i] = scanner.nextInt();
            }
            Arrays.sort(a);
            int gap = 0;
            boolean flag = false;
            for (int i = 0; i < n - 1; i++) {
                int curGap = a[i + 1] - a[i] - 1;
                if (curGap > 1) {
                    flag = true;
                    break;
                } else {
                    gap += curGap;
                }
            }
            if (flag){
                System.out.println("mistake");
            }
            if (gap == 0) {
                System.out.print(a[0] - 1 + " ");
                System.out.print(a[n - 1] + 1);
                System.out.println();
            } else if (gap == 1) {
                for (int i = 0; i < n - 1; i++) {
                    if (a[i + 1] - a[i] == 2) {
                        System.out.println(a[i] + 1);
                        break;
                    }
                }
            }
        }
    }
}*/
  /*  public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        while (scanner.hasNext()) {
            String s1 = scanner.next();
            String s2 = scanner.next();
            int cnt = 0;
            for (int i = 0; i < s1.length(); i++) {
                char c1 = s1.charAt(i);
                char c2 = s2.charAt(i);
                if ((c1 == 'A' && c2 == 'T') ||
                        (c1 == 'T' && c2 == 'A') ||
                        (c1 == 'C' && c2 == 'G') ||
                        (c1 == 'G' && c2 == 'C')) {
                    continue;
                } else {
                    cnt++;
                }
            }
            System.out.println(cnt);
        }
    }
}*/
   /* public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        while (scanner.hasNext()) {
            int n = scanner.nextInt();
            Set<String> set = new HashSet<>();
            for (int i = 0; i < n; i++) {
                char[] cur = scanner.next().toCharArray();
                Arrays.sort(cur);
                set.add(String.valueOf(cur));
            }
            System.out.println(set.size());
        }
    }
}*/
   /* public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        while (scanner.hasNext()) {
            int minSize = scanner.nextInt();
            int maxSize = scanner.nextInt();
            int n = scanner.nextInt();
            List<Integer> list = new ArrayList<>();
            for (int i = 0; i < n; i++) {
                list.add(scanner.nextInt());
            }
            int cnt1 = 0;

            for (int i = minSize; i <= maxSize; i++) {
                boolean flag = false;
                for (int j = 0; j < list.size(); j++) {
                    if (!((i < list.get(j) * 2 || i > list.get(j) * 10) && (list.get(j) < i * 2 || list.get(j) > i * 10))) {
                        flag = true;
                        break;
                }
                if (!flag) {
                    cnt1++;
                } else {
                        flag = false;
                }
                }
            }
            System.out.println(cnt1);
        }
    }
}
*/